import service from '@/utils/request'

export const useRoleApi = (id: number) => {
	return service.post('/api/strator/position/detail', {id})
}
export const useRoleList = () => {
	return service.post('/api/strator/position/list')
}
export const useSetRoleApi = (data: any) => {
	return service.post('/api/strator/position/auth/permission', data)
}
export const useGetRoleApi = (data: any) => {
	return service.post('/api/strator/position/auth/own/permissionIds', data)
}
export const useRoleAddApi = (data: any) => {
	return service.post(data.id ? '/api/strator/position/modify' : '/api/strator/position/add', data)
}
